import 'osc_blog_sys_catalog.dart';
import 'osc_blog_user_catalog.dart';

class OscBlogCatalogListEntity {
	List<OscBlogSysCatalog> blogSysCatalogList;
	List<OscBlogUserCatalog> blogUserCatalogList;

	OscBlogCatalogListEntity({this.blogSysCatalogList, this.blogUserCatalogList});

	OscBlogCatalogListEntity.fromJson(Map<String, dynamic> json) {
		if (json['blog_sys_catalog_list'] != null) {
			blogSysCatalogList = new List<OscBlogSysCatalog>();(json['blog_sys_catalog_list'] as List).forEach((v) { blogSysCatalogList.add(new OscBlogSysCatalog.fromJson(v)); });
		}
		if (json['blog_user_catalog_list'] != null) {
			blogUserCatalogList = new List<OscBlogUserCatalog>();(json['blog_user_catalog_list'] as List).forEach((v) { blogUserCatalogList.add(new OscBlogUserCatalog.fromJson(v)); });
		}
	}

	Map<String, dynamic> toJson() {
		final Map<String, dynamic> data = new Map<String, dynamic>();
		if (this.blogSysCatalogList != null) {
      data['blog_sys_catalog_list'] =  this.blogSysCatalogList.map((v) => v.toJson()).toList();
    }
		if (this.blogUserCatalogList != null) {
      data['blog_user_catalog_list'] =  this.blogUserCatalogList.map((v) => v.toJson()).toList();
    }
		return data;
	}
}
